import { gethuodongApi  } from '../../api/xiaoqu'

export default {
    namespaced: true,
    state: () => ({
        houdongList: [],
        listxq:{}
    }),
    mutations: {
        SET_LIST(state, list) {
            state.houdongList = list
        },
        SET_HDXQ(state, id) {
            state.listxq = {}
            state.listxq = state.houdongList.find((i)=>{
               return i._id == id
            })
        },
    },
    actions: {
        async gethuodong({ commit }, form) {
            const list = await gethuodongApi()
            commit('SET_LIST', list)
        },
       
    },
    getters: {},
    modules: {}
}